<%@ page language="java" contentType="text/html; charset=UTF-8"%>
<%@ include file="/include/taglibs.jsp"%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>iPecker Robot Web Configuration</title>

<link href="styles/huaxia.common.validator.css" rel="stylesheet"
	type="text/css" />
<link href="styles/huaxia.common.message.css" rel="stylesheet"
	type="text/css" />
<link href="styles/huaxia.common.input.css" rel="stylesheet"
	type="text/css" />

<script type="text/javascript" src="scripts/public.prototype.js"></script>
<script type="text/javascript" src="scripts/huaxia.common.validator.js"></script>
<script type="text/javascript" src="scripts/huaxia.common.message.js"></script>


<style type="text/css">
* {
	font-family: Arial, Verdana, Helvetica, sans-serif;
	font-size: 9pt;
}

#lp {
	text-align: center;
}

#lp div {
	width: 60%;
	margin: auto;
}

.property {
	color: #fff;
	font-weight: bold;
	height: 24px;
	line-height: 24px;
	text-align: left;
}

.value input {
	font-size: 18px;
	width: 100%;
}

#confirm {
	padding: 16px 0px 0px 0px;
	text-align: right;
}

#confirm button {
	height: 32px;
	line-height: 32px;
	font-weight: bold;
	width: 96px;
}
</style>
</head>
<script type="text/javascript">
if(window.top.location != window.location){
	window.top.location = window.location;
}
if(${!empty error}){
	alert("${error}");
}
</script>
<body style="background-color: #454545">
<table width="100%" height="100%" border="0" cellpadding="0"
	cellspacing="0">
	<tr>
		<td align="center" valign="middle">
		<table border="0" cellspacing="6" cellpadding="0">
			<tr>
				<td width="500px" height="355"
					style="background-color: #dedede; border: 1px solid #fff;">
				<table width="100%" height="100%" border="0" cellpadding="0"
					cellspacing="0">
					<tr>
						<td align="center" valign="bottom">
						<div id="errormsgspace" style="display: none; width: 500px"></div>
						<div id="successmsgspace" style="display: none; width: 500px"></div>
						
						<table border="0" cellspacing="6" cellpadding="0"
							style="margin: 0px 0px 19px 0px; background-image: url('./images/login_panel_shadow.jpg'); background-repeat: no-repeat; background-position: center;">
							<tr>
								<td id="lp" width="450" height="300"
									style="border: 1px solid #fff; background-image: url('./images/login_panel_bg.png'); background-repeat: repeat-x;">
								<form name="frmlogin" method="post" action="Login.do">

								<div class="property">用户名:</div>
								<div class="value"><input name="username" type="text"
									id="username" maxlength="16" value="${username}"></div>
								<div class="property">密 码:</div>
								<div class="value"><input name="password" type="password"
									id="password" maxlength="16"></div>
								<div id="confirm">
								<button name="btnlogin" type="submit">登 陆</button>
								</div>
								</form>
								</td>
							</tr>
						</table>
						</td>
					</tr>
				</table>
				</td>
			</tr>
		</table>
		</td>
	</tr>
</table>
<script type="text/javascript">
			<c:set var="exceptionType">org.apache.struts.action.EXCEPTION</c:set>
			<c:set var="exception" value="${requestScope[exceptionType]}" />
			var error_msgs = new messager('errormsgspace',{messageType : 'ERROR', isImmediate : true});
			
			<c:if test="${exception != null}">
					error_msgs.addMessage('${exception.message}','<bean:message key="${exception.message}" bundle="${exception.bundle}" />');
			</c:if>
			
			var success_msgs = new messager('successmsgspace',{messageType : 'INFORMATION', isImmediate : true});
			
			<c:forEach var='message' items="${MessageCenter.messages}">
					success_msgs.addMessage('${message.message}','<bean:message key="${message.message}" bundle="${message.bundle}" />');
			</c:forEach>
		
</script>
</body>
</html>
